package com.example.testlauncher;

import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.view.View;

public class MainActivity extends Activity {

	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		setContentView(R.layout.activity_main);
		findViewById(R.id.button).setOnClickListener(
				new View.OnClickListener() {

					@Override
					public void onClick(View v) {
						startActivity(new Intent(MainActivity.this,
								SecondActivity.class));

					}
				});
	}

	@Override
	protected void onResume() {
		super.onResume();

		if (getIntent().getBooleanExtra(ChooserActivity.CLOSE_LAUNCHER, false)) {
			finish();
		}
	}

}
